package com.xu.finalshell.activation;

import com.xu.finalshell.activation.enums.UpgradeVersionEnum;
import com.xu.finalshell.activation.util.ActivationUtil;

import java.util.Scanner;

/**
 * 启动类
 *
 * @author xuguan
 * @since 2024/6/18
 */
public class Application {
    public static void main(String[] args) {
        final Scanner sc = new Scanner(System.in);
        System.out.println("请输入机器码: ");
        final String machineCode = sc.nextLine();
        System.out.println("版本号 >= 3.9.6 (新版)");
        System.out.println(UpgradeVersionEnum.ADVANCED.getDesc() + ": " + ActivationUtil.newVersionCode(machineCode, UpgradeVersionEnum.ADVANCED));
        System.out.println(UpgradeVersionEnum.PROFESSIONAL.getDesc() + ": " + ActivationUtil.newVersionCode(machineCode, UpgradeVersionEnum.PROFESSIONAL));
        System.out.println();
        System.out.println("版本号 < 3.9.6 (旧版)");
        System.out.println(UpgradeVersionEnum.ADVANCED.getDesc() + ": " + ActivationUtil.oldVersionCode(machineCode, UpgradeVersionEnum.ADVANCED));
        System.out.println(UpgradeVersionEnum.PROFESSIONAL.getDesc() + ": " + ActivationUtil.oldVersionCode(machineCode, UpgradeVersionEnum.PROFESSIONAL));
    }
}
